<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:p="http://primefaces.prime.com.tr/ui"
      xmlns:ui="http://java.sun.com/jsf/facelets">
    <h:head>
        <title>Send private message</title>
    </h:head>
    <h:body>
        <ui:composition template="../communityTemplate.xhtml">
            
            <ui:define name="left">
                <ul>
                    <li>
                        <a href="/RomaCommunityv1/PrivateMessage/listmessages.jsf">List messages</a>
                    </li>
                    
                    <li>
                        <a href="/RomaCommunityv1/PrivateMessage/sendmessage.jsf">Send message</a>
                    </li>
                </ul>
                
            </ui:define>

            <ui:define name="content">

                <h:form>


                    <!-- <p:panel header="AutoComplete" toggleable="false">
                        <h:panelGrid columns="2" cellpadding="5"> -->
                    <table>
                        <tr>
                            <td width="60px">
                                <h:outputLabel value="Name :"/>  
                            </td>
                            <td width="300px">
                                <p:autoComplete id="autocomplete" value="#{sendMessageBean.receivername}" 
                                                completeMethod="#{sendMessageBean.complete}" size="40" /> 
                            </td>
                        </tr>
                        <tr>
                            <td>
                                <h:outputLabel value="Message :" /> 
                            </td>
                            <td>
                                <p:inputTextarea value="#{sendMessageBean.message}" autoResize="TRUE" cols="43" rows="20"/> 

                            </td>
                        </tr>
                        <tr>
                            <td>

                            </td>
                            <td>
                                <p:commandButton value="Send" action="#{sendMessageBean.sendMessage}" ajax="FALSE"/> 

                            </td>
                        </tr>
                    </table>


                </h:form>
            </ui:define>
        </ui:composition>

    </h:body>
</html>

